package com.hqj.config;

import com.baomidou.mybatisplus.core.config.GlobalConfig;
import com.baomidou.mybatisplus.extension.plugins.PaginationInterceptor;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * @author 黄啟军
 * @version 1.0
 * @date 2020/10/7/007
 */
@Configuration
public class MybatisPlusConfig {
        @Bean
        public PaginationInterceptor paginationInterceptor() {
            return new PaginationInterceptor();
        }
        @Bean
        public GlobalConfig globalConfig() {
            GlobalConfig globalConfig = new GlobalConfig();
//            globalConfig.setMetaObjectHandler(new MybatisPlusHandler());
            return globalConfig;
        }
}
